﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace SmallERP.PrintManage
{
    public partial class FrmPaperTitle : Form
    {
        public FrmPaperTitle()
        {
            InitializeComponent();
        }

        private void txtPaperTitle_Enter(object sender, EventArgs e)
        {
            btnOk.PerformClick();
        }

        private void btnOk_Click(object sender, EventArgs e)
        {
            if (string.IsNullOrEmpty(txtPaperTitle.Text.Trim()))
            {
                MessageBox.Show("请输入纸头长度","提示",MessageBoxButtons.OK,MessageBoxIcon.Information);
                txtPaperTitle.Focus();
                return;
            }
            ((FrmChangePaper)(this.Owner)).PaperTitle = Convert.ToDouble(txtPaperTitle.Text)/100;
            this.Close();
        }

        private void FrmPaperTitle_Load(object sender, EventArgs e)
        {
            txtPaperTitle.Focus();
        }
    }
}
